Skip to content

Default to dark theme for EC#7162

Open
toger5 wants to merge 1 commit into
element-hq:developfrom
toger5:toger5/dark-theme-ec
Open

Default to dark theme for EC#7162
toger5 wants to merge 1 commit into
element-hq:developfrom
toger5:toger5/dark-theme-ec

Conversation

@toger5

@toger5 toger5 commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

(this is the intended design on light and dark system configuration)

Content

This change is related (and required) for: element-hq/element-call#4067

Motivation and context

element-hq/element-call#4067

Tested devices

  • Physical
  • Emulator
  • OS version(s):

Checklist

  • I am aware of the etiquette.
  • This PR was made with the help of AI:
    • Yes. In this case, please request a review by Copilot.
    • No.
  • Changes have been tested on an Android device or Android emulator with API 24
  • UI change has been tested on both light and dark themes
  • Accessibility has been taken into account. See https://github.com/element-hq/element-x-android/blob/develop/CONTRIBUTING.md#accessibility
  • Pull request is based on the develop branch
  • Pull request title will be used in the release note, it clearly defines what will change for the user
  • Pull request includes screenshots or videos if containing UI changes
  • You've made a self review of your PR

@toger5 toger5 requested a review from a team as a code owner July 7, 2026 10:37
@toger5 toger5 requested review from ganfra and removed request for a team July 7, 2026 10:37
@github-actions

github-actions Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Thank you for your contribution! Here are a few things to check in the PR to ensure it's reviewed as quickly as possible:

  • If your pull request adds a feature or modifies the UI, this should have an equivalent pull request in the Element X iOS repo unless it only affects an Android-only behaviour or is behind a disabled feature flag, since we need parity in both clients to consider a feature done. It will also need to be approved by our product and design teams before being merged, so it's usually a good idea to discuss the changes in a Github issue first and then start working on them once the approach has been validated.
  • Your branch should be based on origin/develop, at least when it was created.
  • The title of the PR will be used for release notes, so it needs to describe the change visible to the user.
  • The test pass locally running ./gradlew test.
  • The code quality check suite pass locally running ./gradlew runQualityChecks.
  • If you modified anything related to the UI, including previews, you'll have to run the Record screenshots GH action in your forked repo: that will generate compatible new screenshots. However, given Github Actions limitations, it will prevent the CI from running temporarily, until you upload a new commit after that one. To do so, just pull the latest changes and push an empty commit.

@codecov

codecov Bot commented Jul 7, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 16 lines in your changes missing coverage. Please review.
✅ Project coverage is 80.52%. Comparing base (7c3d1e2) to head (ed48c03).

Files with missing lines Patch % Lines
...droid/features/call/impl/ui/ElementCallActivity.kt 0.00% 16 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #7162      +/-   ##
===========================================
- Coverage    80.53%   80.52%   -0.02%     
===========================================
  Files         2705     2705              
  Lines        78030    78033       +3     
  Branches     10532    10532              
===========================================
- Hits         62843    62837       -6     
- Misses       11128    11137       +9     
  Partials      4059     4059              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bmarty bmarty left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think a better way to do this is to force the Dark theme at the Activity level:
Add the lines:

                ForcedDarkElementTheme(
                    colors = colors,
                ) {

at the beginning of the block ElementThemeApp in the class ElementCallActivity.

That should do it and also take care of the status bar and other side effects of forcing the theme to dark.

Here is a patch:
elementCallDarkTheme.patch

@toger5

toger5 commented Jul 7, 2026

Copy link
Copy Markdown
Contributor Author

I think a better way to do this is to force the Dark theme at the Activity level:

This indeed sounds like a smarter way. I like it

@toger5 toger5 force-pushed the toger5/dark-theme-ec branch from d7c2283 to f4741c2 Compare July 7, 2026 15:48
(this is the intended design on light and dark system configuration)
@toger5 toger5 force-pushed the toger5/dark-theme-ec branch from f4741c2 to ed48c03 Compare July 7, 2026 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants